package com.learn.project2.controller.admin;

import com.learn.project2.model.bo.admin.user.UserListBO;
import com.learn.project2.model.vo.admin.address.AddressListVO;
import com.learn.project2.service.admin.address.AddressService;
import com.learn.project2.utils.Result;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @description: 收货地址
 * @author wxy
 * @date 2022-01-09 20:41
 * @version 1.0
 */
@RequestMapping("admin/address")
@RestController
public class AddressController {

    @Autowired
    AddressService addressService;
    @RequestMapping("list")
    public Result list(String name, Integer userId, UserListBO userListBO){

        AddressListVO addressListVO = addressService.selectAddress(name,userId,userListBO);

        return Result.ok(addressListVO);
    }
}
